package com.hspedu.seckill.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.hspedu.seckill.pojo.User;
import com.hspedu.seckill.vo.LoginVo;
import com.hspedu.seckill.vo.RespBean;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

public interface UserService extends IService<User> {

    //完成用户的登录校验
    RespBean doLogin(LoginVo loginVo, HttpServletRequest request, HttpServletResponse response);

    //根据Cookie-ticket 获取用户的信息
    User getUserByCookie(String userTicket,
                         HttpServletRequest request,
                         HttpServletResponse response);

    //更新用户密码
    RespBean updatePassword(String userTicket,
                         String password,
                         HttpServletRequest request,
                         HttpServletResponse response);

}
